<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path;
%>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=0">
<title>云校通-家长</title>
<jsp:include page="/WEB-INF/page/common/_header.jsp"></jsp:include>
<script>
	$(function(){
		$('#slide2').swipeSlide({
		autoSwipe:true,//自动切换默认是
		speed:3000,//速度默认4000
		continuousScroll:true,//默认否
		transitionType:'cubic-bezier(0.22, 0.69, 0.72, 0.88)',//过渡动画linear/ease/ease-in/ease-out/ease-in-out/cubic-bezier
		lazyLoad:true,//懒加载默认否
		firstCallback : function(i,sum,me){
		            me.find('.dot').children().first().addClass('cur');
		        },
		        callback : function(i,sum,me){
		            me.find('.dot').children().eq(i).addClass('cur').siblings().removeClass('cur');
		        }
		});
	
	});   
</script>
</head>
<body ontouchstart>
	<div class="weui_tab tab-bottom">
		<div class="weui_tab_bd">
			<!--幻灯片广告-->
			<div class="slide" id="slide2">
			    <ul>
			        <li> 
			        	<a href="https://mp.weixin.qq.com/s/VV4z2KVX-ecnhyErHNto7Q">
			                <img src="<%=basePath %>/images/banner/banner1.jpg" data-src="<%=basePath %>/images/banner/banner1.jpg" alt="">
			            </a>
			        </li>
			        <li> 
			        	<a href="https://mp.weixin.qq.com/s/aKXdIBwqBv2nE8yMm7ZgcA">
			                <img src="<%=basePath %>/images/banner/banner2.jpg" data-src="<%=basePath %>/images/banner/banner2.jpg" alt="">
			            </a>
			        </li>
			    </ul>
			    <div class="dot">
			        <span></span>
			        <span></span>
			    </div>
			</div>
			<div class="page-bd" style="margin-top: 10px;">
		        <div class="weui-flex" style="padding: 5px 10px 5px 10px;">
		            <c:forEach items="${user.resourceList}" var="itm" begin="0" end="3" varStatus="status">
		        		<div class="weui-flex-item" style="left:0;">
		        			<div class="placeholder">
		        				<a href="<c:choose><c:when test='${itm.isExtLink == "N" }'><%=basePath%>${user.currUrl}${itm.resourceUrlValue}&sid=${user.parent.studentId }</c:when><c:otherwise>${itm.resourceUrlValue}&openid=${user.openid }&sid=${user.parent.studentId }</c:otherwise></c:choose>">
		        					<img src="<%=basePath %>/images/${itm.icon}"/> ${itm.resourceName }
		        				</a>
		        			</div>
		        		</div>
		        		<c:if test="${status.count%2 == 0}" >
		        			</div>
		        			<div class="weui-flex" style="padding: 5px 10px 5px 10px;">
		        		</c:if>
		        	</c:forEach>
		        </div>
		    </div>
		    <!--广告-->
		    <div class="gg">
		    		<img src="<%=basePath %>/images/57901f87192a4_1024@3x.png" class="img-max"/>
		    </div>
			<!--End广告-->
			<!--九宫格-->
			<div class="weui_grids index_grids">
		        <c:forEach items="${user.resourceList}" var="itm" begin="4" end="9">
			        <a href="<c:choose><c:when test='${itm.isExtLink == "N" }'><%=basePath%>${user.currUrl}${itm.resourceUrlValue}&sid=${user.parent.studentId }</c:when><c:otherwise>${itm.resourceUrlValue}&openid=${user.openid }&sid=${user.parent.studentId }</c:otherwise></c:choose>" class="weui_grid js_grid"  >
		                <div class="weui_grid_icon">
		                    <img src="<%=basePath %>/images/${itm.icon}" alt="${itm.resourceName }">
		                </div>
		                <p class="weui_grid_label ellipsis_box">
		                    ${itm.resourceName }
		                </p>
		            </a>
		        </c:forEach>
	        </div>
			<!--End九宫格-->
		</div>
	</div>
	<jsp:include page="/WEB-INF/page/common/_footer.jsp"></jsp:include>
</body>
</html>